Skip to content

Add Slack bot print endpoint - #1

Open
KaBankz wants to merge 3 commits into
masterfrom
feat/slack-bot
Open

Add Slack bot print endpoint#1
KaBankz wants to merge 3 commits into
masterfrom
feat/slack-bot

Conversation

@KaBankz

@KaBankz KaBankz commented Apr 16, 2026

Copy link
Copy Markdown
Owner

Summary

  • Adds POST /webhooks/slack endpoint that accepts pre-formatted markdown content and prints it directly on the receipt printer
  • Supports inline images via ![alt](url) markdown syntax (downloaded and printed inline in content flow)
  • Optional bearer token auth, header/footer/QR code toggles, and paper cut control
  • Includes SKILL.md consumer spec with full API reference, supported markdown, receipt dimensions, and examples

New files

  • src/papercut/platforms/slack/ — config, models, router (follows existing Linear platform pattern)
  • SKILL.md — complete API spec for any consumer/agent to integrate with

Modified files

  • src/papercut/core/printer.pyprint_raw_receipt(), image download + inline rendering
  • src/papercut/core/console.pyprint_raw_console_preview() for dev/debug
  • config.py — Slack provider config loading
  • src/papercut/api.py — conditional Slack router registration
  • papercut.toml / papercut-schema.json[providers.slack] config section

Simplest usage

curl -X POST http://localhost:8000/webhooks/slack \
  -H "Content-Type: application/json" \
  -d '{"content": "# Hello\n\nThis is a **test** print."}'

KaBankz added 2 commits April 15, 2026 22:20
Adds POST /webhooks/slack that accepts pre-formatted markdown content
and prints it directly on the receipt printer. Supports inline images
via ![alt](url) syntax, optional header/footer/QR code, and optional
bearer token auth. Includes SKILL.md spec for consumer integration.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant